package game.module.battlereport.dao;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import game.RoomServer;
import game.module.battlereport.bean.PlayerReport;

public class PlayerReportDBHelper {
	
	private static Logger logger = LoggerFactory.getLogger(PlayerReportDBHelper.class);
	
	static class SingletonHolder {
		static PlayerReportDBHelper instance = new PlayerReportDBHelper();
	}
	
	public static PlayerReportDBHelper getInstance() {
		return SingletonHolder.instance;
	}
	
	public void asyncAddPlayerReport(final PlayerReport playreport ) {
		RoomServer.executorService.execute(new Runnable() {
			
			@Override
			public void run() {
				// TODO Auto-generated method stub
				PlayReportDBDao.getInstance().addPlayReport(playreport);
			}
		});
	}
}
